import * as THREE from "three";

const textureLoader = new THREE.TextureLoader();

export function loadTexture(url: string, flipY = false) {
    const texture = textureLoader.load(url);
    texture.colorSpace = THREE.SRGBColorSpace;
    texture.flipY = flipY;
    return texture;
}